﻿using System.Windows;
using System.Windows.Media;

namespace CustomerAssistant
{
    /// <summary>
    /// MessageWindow.xaml 的交互逻辑
    /// </summary>
    public partial class MessageWindow : Window
    {
        public MessageWindow()
        {
            InitializeComponent();
        }

        public void ShowMessage(string msg, ImageSource imageSrc)
        {
            lock (this)
            {
                image1.Source = imageSrc;
                textBlock1.Text = msg;
                ShowDialog();
            }
        }

        private void button1_Click(object sender, RoutedEventArgs e)
        {
            Hide();
        }
    }
}